<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
<!-- permette di usare tag tipo foreach -->
<%@ page isELIgnored="false"%>
<!DOCTYPE html>
<html lang=it>

<head>
<title>Forum</title>
<meta charset="UTF-8">
<jsp:include page="partials/stylesheetChooser.jsp" />
</head>

<body>
	<div class="header">
		<div class="site-title">Settings</div>
	</div>

	<div class="content">
		<div>
			<form method="post">
				Stile personalizzato del forum: <select name="styles">
					<option value="Seleziona stile">Seleziona stile</option>
					<option value="default">default</option>
					<c:forEach items="${styles}" var="style">
						<c:set var="cssName"
							value="${fn:substringBefore(style.name, '.css')}" />
						<option value="${style.name}">${cssName}</option>
					</c:forEach>
				</select> <input type="submit" id="login_button" class="button" value="Salva">
			</form>
		</div>
	</div>

	<div>
		<p style="color: green;">
			<%
				String a = request.getParameter("savedmessage");
				if (a != null)
					out.println(a);
			%>
		</p>
	</div>

	<div>
		<a href="/login-in-prestito/forum">Torna indietro</a>
	</div>

</body>



</html>